package com.itheima02;

import java.util.TreeMap;

public class Tset01 {
    public static void main(String[] args) {
        TreeMap<Student, String> tm = new TreeMap<>();

        Student s1 = new Student("zhangsan", 15);
        Student s2 = new Student("lisi", 17);
        Student s3 = new Student("wangwu", 15);
        Student s4 = new Student("zhangsan", 16);

        tm.put(s1, "天津");
        tm.put(s2, "北京");
        tm.put(s3, "上海");
        tm.put(s4, "福建");

        tm.forEach((Student key, String vaule) -> System.out.println(key + "......." + vaule));

    }
}
